/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package opk.Solver;

import java.awt.Point;
import java.util.ArrayList;
import opk.Generator.Edge;
import opk.Generator.Shape;

/**
 *
 * @author Dawid
 */
public class ResultShape extends Shape
{
    private int numberOfShapes;
    private double ratio;

    public ResultShape(ArrayList<Point> points)
    {
        super(points);

    }

    ResultShape()
    {
    }

  
    /**
     * @return the numberOfShapes
     */
    public int getNumberOfShapes()
    {
        return numberOfShapes;
    }

    /**
     * @param numberOfShapes the numberOfShapes to set
     */
    public void setNumberOfShapes(int numberOfShapes)
    {
        this.numberOfShapes = numberOfShapes;
    }

    /**
     * @return the ratio
     */
    public double getRatio()
    {
        return ratio;
    }

    /**
     * @param ratio the ratio to set
     */
    public void setRatio(double ratio)
    {
        this.ratio = ratio;
    }

    public ArrayList<Point> getShapePoints()
    {
        return nodes;
    }

    public static ArrayList<Point> edgesToPoints(ArrayList<Edge> edges)
    {
        ArrayList<Point> points = new ArrayList<Point>(edges.size());
        for (Edge edge : edges)
        {
            points.add(edge.getGraphPoint1());
        }

        return points;
    }

}
